﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Battle
{
    public class Buff_MoveSpeed : BuffHandlerBase<EnemyMoveBase>
    {
        public Buff_MoveSpeed(string name, EM_BuffAddType buffAddType = EM_BuffAddType.Normal) : base(name, buffAddType)
        {
        }

        public override void OnBuffStart(IBuffMgr buffMgr, ST_ObjBuffData buffData)
        {
            base.OnBuffStart(buffMgr, buffData);

            buffMgr.GetObj<EnemyMoveBase>()?.MoveSpeed.AddChange(buffData.strGUID,buffData.fNum);
        }
        public override void OnBuffEnd(IBuffMgr buffMgr, ST_ObjBuffData buffData)
        {
            base.OnBuffEnd(buffMgr, buffData);

            buffMgr.GetObj<EnemyMoveBase>()?.MoveSpeed.RemoveChange(buffData.strGUID);
        }

        public override string[] OnUpdate(IBuffMgr buffMgr, ST_ObjBuffData[] buffDatas, float deltaTime)
        {
            return null;
        }
    }
}
